<{extend name="public/layout"}>


<{block name="content"}>
<div class="content-wrapper">
    <!-- 面包屑导航 -->
    <section class="content-header">
        <div class="container-fluid">
            <div class="row mb-2">
                <div class="col-sm-6">

                </div>
                <div class="col-sm-6">
                    <ol class="breadcrumb float-sm-right">
                        <li class="breadcrumb-item"><a href="<{:url('/admin/index/index')}>">首页</a></li>
                        <li class="breadcrumb-item"><a href="#">系统设置</a></li>
                        <li class="breadcrumb-item active">网站配置</li>
                    </ol>
                </div>
            </div>
        </div>
    </section>

    <!-- 内容区-->
    <section class="content">
        <div class="container-fluid">
            <div class="row">
                <!-- left column -->
                <div class="col-md-12">

                    <div class="card card-primary">

                        <form method="post" action="<{:url('/admin/system.index/web_action')}>" id="check-form">
                            <div class="card-body">
                                <div class="form-group">
                                    <label for="title">网站标题</label>
                                    <input name="title" autocomplete="off" value="<{$data?$data.title:'后台管理'}>" type="text" class="form-control" id="title" placeholder="网站标题">
                                    <span class="bs-red">后台浏览器标题</span>
                                </div>
                                <div class="form-group">
                                    <label for="enable_reg">是否开放注册</label>
                                    <select name="enable_reg" class="form-control" id="enable_reg">
                                        <option <{if !empty($data.enable_reg)&&$data.enable_reg=='1'}>selected<{/if}>  value="1">是</option>
                                        <option <{if !empty($data.enable_reg)&&$data.enable_reg=='-1'}>selected<{/if}> value="-1">否</option>
                                    </select>
                                </div>
                                <div class="form-group">
                                    <label for="sms_type">发送短信验证码</label>
                                    <select name="sms_type" class="form-control" id="sms_type">
                                        <option <{if !empty($data.sms_type)&&$data.sms_type=='yunpian'}>selected<{/if}>  value="yunpian">云片</option>
                                        <option <{if !empty($data.sms_type)&&$data.sms_type=='aliyun'}>selected<{/if}>  value="aliyun">阿里云</option>
                                    </select>
                                    <span class="bs-red">要配置短信后才能发送， <a class="btn btn-xs btn-success" href="<{:url('/admin/system.index/sms')}>">去配置</a> </span>
                                </div>

                                <div class="form-group">
                                    <label for="upload_type">文件上传方式</label>
                                    <select name="upload_type" class="form-control" id="upload_type">
                                        <option <{if !empty($data.upload_type)&&$data.upload_type=='local'}>selected<{/if}>  value="local">本地</option>
                                        <option <{if !empty($data.upload_type)&&$data.upload_type=='qiniu'}>selected<{/if}> value="qiniu">七牛</option>
                                        <option <{if !empty($data.upload_type)&&$data.upload_type=='oss'}>selected<{/if}> value="oss">阿里OSS</option>
                                    </select>
                                    <span class="bs-red">文件上传位置，默认本地保存。 <a class="btn btn-outline-success btn-xs" href="<{:url('upload')}>">去配置相关参数</a> </span>
                                </div>
                                <div class="form-group">
                                    <label for="upload_fileSizeLimit">文件上传限制</label>
                                    <input type="number" value="<{:isset($data.upload_fileSizeLimit)?$data.upload_fileSizeLimit:'2'}>"   min="0" name="upload_fileSizeLimit" id="upload_fileSizeLimit" class="form-control">
                                    <span class="bs-red">限制上传大小，单位b，如1048576代表1M</span>
                                </div>
                                <div class="form-group">
                                    <label for="upload_enable_type">文件上传允许类型</label>
                                    <input type="text" value="<{:isset($data.upload_enable_type)?$data.upload_enable_type:'jpg;png;jpeg'}>"  name="upload_enable_type" id="upload_enable_type" class="form-control">
                                    <span class="bs-red">允许上传的文件类型后缀名，多个用分号隔开，如jpg;png;jpeg;zip</span>
                                </div>


                            </div>
                            <div class="card-footer">
                                <button type="button" onclick="layer.confirm('确定提交保存吗',{title:0},function() {
                                      form_submit()
                                    })" class="btn btn-primary">提交保存</button>
                            </div>
                        </form>
                    </div>

                </div>

            </div>

        </div>
    </section>
</div>
<{/block}>